import React, { Component } from 'react';
import {observer} from "mobx-react";
import Mobx from '../mobx'
@observer class InformationComment extends Component {
    constructor(props) {
        super(props)
    }
    render() {
        return (
            <div className="InformationComment">
                <p className='title'>评论（{this.props.total}）</p>
                <div className='commentAll'>
                    {
                        this.props.comment.map((item,index)=>{
                            return(
                                <div className='commentOne' key={index}>
                                    <div className='left'>
                                        <img src={item.headPic} alt=""/>
                                    </div>
                                    <div className='right'>
                                        <p className='title shengluehao'>{item.username}</p>
                                        <p className='time shengluehao'>{item.createDate}</p>
                                    </div>
                                    <p className='clear'></p>
                                    <div className='content'>
                                        {item.content}
                                    </div>
                                </div>
                            )
                        })
                    }
                </div>
            </div>
        );
    }
}

export default InformationComment;
